/**
  ******************************************************************************
  * @file 
  * @author
  * @version
  * @date   
  * @brief  
  ******************************************************************************
	* @attention
  *
  * <h2><center>&copy; COPYRIGHT 2012 STMicroelectronics</center></h2>
  *
  * Licensed under MCD-ST Liberty SW License Agreement V2, (the "License");
  * You may not use this file except in compliance with the License.
  * You may obtain a copy of the License at:
  *
  *        http://www.st.com/software_license_agreement_liberty_v2
  *
  * Unless required by applicable law or agreed to in writing, software 
  * distributed under the License is distributed on an "AS IS" BASIS, 
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
  *
  ******************************************************************************
  */
  
/* Define to prevent recursive inclusion -------------------------------------*/
#ifndef __RTC_H
#define __RTC_H

/* Includes ------------------------------------------------------------------*/
/* Exported types ------------------------------------------------------------*/
/* Exported constants --------------------------------------------------------*/
/* Exported macro ------------------------------------------------------------*/
#define RTC_OFFSET               (RTC_BASE - PERIPH_BASE)
#define RTC_CR_OFFSET            (RTC_OFFSET + 0x08)
#define RTC_CR_WUTE_BIT           10
#define RTC_CR_WUTE_BB           (PERIPH_BB_BASE + (RTC_CR_OFFSET * 32) + (RTC_CR_WUTE_BIT * 4))

#define RTC_ISR_OFFSET           (RTC_OFFSET + 0x0C)
#define RTC_ISR_WUTF_BIT          10
#define RTC_ISR_WUTF_BB          (PERIPH_BB_BASE + (RTC_ISR_OFFSET * 32) + (RTC_ISR_WUTF_BIT * 4))

/* Exported functions ------------------------------------------------------- */
void RTC_Config(void);
void RTC_SetWakeUp(__IO uint32_t time_ms);

#endif /* __RTC_H */

/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
